﻿using System;
using System.Collections.Generic;
using System.Text;
using Solution.Repository.Interfaces.Base;

namespace Solution.Services.Employee
{
    public class EmployeeServices : IEmployeeServices
    {
        private readonly IEmployeeRepository  _employeeRepository;

        public EmployeeServices(IEmployeeRepository employeeRepository)
        {
            _employeeRepository = employeeRepository;
        }
        

        public dynamic Login(string name, string pwd)
        {
            return _employeeRepository.FirstOrDefault(u => u.empLoginName == name && u.empLoginPwd == pwd);
        }
    }
}
